/**
 * 
 */
package co.fitstart.mobile.service;

import java.util.List;

import com.demo2do.core.service.GenericService;

import co.fitstart.entity.product.Product;
import co.fitstart.entity.product.ProductType;
import co.fitstart.entity.product.Tag;

/**
 * @author downpour
 *
 */
public interface ProductService extends GenericService<Product> {
    
    /**
     * list products by type
     * 
     * @param productType
     * @return
     */
    public List<Product> list(ProductType productType);
    
    /**
     * list products by type and tag
     * 
     * @param productType
     * @param tag
     * @return
     */
    public List<Product> list(ProductType productType, Tag tag);
    
    /**
     * Read product
     * 
     * @param product
     * @param openid
     * @param source 
     */
    public void readProduct(Product product, String openid, String source);
    
    /**
     * Share product
     * 
     * @param product
     * @param openid
     */
    public void shareProduct(Product product, String openid);
    
    /**
     * Order product
     * 
     * @param product
     * @param openid
     * @param source 
     */
    public void orderProduct(Product product, String openid, String source);
    
    
}
